package com.example.wxselectdemo;

import java.util.ArrayList;

import com.gx303.wximageselect.PopWxImageSelect;
import com.gx303.wximageselect.Inter.ImageSelectInterface;
import com.gx303.wximageselect.Inter.ImageSendInterface;
import com.gx303.wximageselect.bean.Image;

import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.widget.Toast;

public class MainActivity extends Activity {

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_main);
	}

	public void choicePic(View v)
	{
		com.gx303.wximageselect.PopWxImageSelect pop1=new PopWxImageSelect(this,3,new ImageSendInterface() {
			
			@Override
			public void send(ArrayList<Image> images) {
				// TODO Auto-generated method stub
				Toast.makeText(getApplicationContext(), "发送了"+images.size()+"张图片", Toast.LENGTH_SHORT).show();
			}

			@Override
			public void takephoto() {
				// TODO Auto-generated method stub
				Toast.makeText(getApplicationContext(), "选择了拍照", Toast.LENGTH_SHORT).show();
			}
		});
		pop1.startSelect(v);
	}
	

}
